package org.ycx.doc.dao.model;

import java.io.Serializable;
import java.util.Date;
import org.ycx.common.annotation.FormDesc;

@FormDesc(pk="moduleId")
public class DocModule implements Serializable {
    /** 模块编号 */
    @FormDesc(name="模块编号",maxLength=10,type=1)
    private Integer moduleId;

    /** 项目编号 */
    @FormDesc(name="项目编号",maxLength=10,type=1)
    private Integer appId;

    /** 模块名称 */
    @FormDesc(name="模块名称",maxLength=200,type=0)
    private String moduleName;

    /** 模块类型 */
    @FormDesc(name="模块类型",maxLength=10,type=1)
    private Integer moduleType;

    /** 父节点 */
    @FormDesc(name="父节点",maxLength=10,type=1)
    private Integer pid;

    /** 模块唯一码 */
    @FormDesc(name="模块唯一码",maxLength=64,type=0)
    private String moduleCode;

    /** 版本号 */
    @FormDesc(name="版本号",maxLength=10,type=1)
    private Integer mVersion;

    /** 创建时间 */
    @FormDesc(name="创建时间",maxLength=10,type=3)
    private Date createTs;

    /** 创建人 */
    @FormDesc(name="创建人",maxLength=10,type=1)
    private Integer createUid;

    /** 更新时间 */
    @FormDesc(name="更新时间",maxLength=10,type=3)
    private Date updateTs;

    /** 更新人 */
    @FormDesc(name="更新人",maxLength=10,type=1)
    private Integer updateUid;

    /** 状态 */
    @FormDesc(name="状态",maxLength=10,type=1)
    private Integer states;

    private static final long serialVersionUID = 1L;

    public Integer getModuleId() {
        return moduleId;
    }

    public void setModuleId(Integer moduleId) {
        this.moduleId = moduleId;
    }

    public Integer getAppId() {
        return appId;
    }

    public void setAppId(Integer appId) {
        this.appId = appId;
    }

    public String getModuleName() {
        return moduleName;
    }

    public void setModuleName(String moduleName) {
        this.moduleName = moduleName;
    }

    public Integer getModuleType() {
        return moduleType;
    }

    public void setModuleType(Integer moduleType) {
        this.moduleType = moduleType;
    }

    public Integer getPid() {
        return pid;
    }

    public void setPid(Integer pid) {
        this.pid = pid;
    }

    public String getModuleCode() {
        return moduleCode;
    }

    public void setModuleCode(String moduleCode) {
        this.moduleCode = moduleCode;
    }

    public Integer getmVersion() {
        return mVersion;
    }

    public void setmVersion(Integer mVersion) {
        this.mVersion = mVersion;
    }

    public Date getCreateTs() {
        return createTs;
    }

    public void setCreateTs(Date createTs) {
        this.createTs = createTs;
    }

    public Integer getCreateUid() {
        return createUid;
    }

    public void setCreateUid(Integer createUid) {
        this.createUid = createUid;
    }

    public Date getUpdateTs() {
        return updateTs;
    }

    public void setUpdateTs(Date updateTs) {
        this.updateTs = updateTs;
    }

    public Integer getUpdateUid() {
        return updateUid;
    }

    public void setUpdateUid(Integer updateUid) {
        this.updateUid = updateUid;
    }

    public Integer getStates() {
        return states;
    }

    public void setStates(Integer states) {
        this.states = states;
    }

    @Override
    public String toString() {
        StringBuilder sb = new StringBuilder();
        sb.append(getClass().getSimpleName());
        sb.append(" [");
        sb.append("Hash = ").append(hashCode());
        sb.append(", moduleId=").append(moduleId);
        sb.append(", appId=").append(appId);
        sb.append(", moduleName=").append(moduleName);
        sb.append(", moduleType=").append(moduleType);
        sb.append(", pid=").append(pid);
        sb.append(", moduleCode=").append(moduleCode);
        sb.append(", mVersion=").append(mVersion);
        sb.append(", createTs=").append(createTs);
        sb.append(", createUid=").append(createUid);
        sb.append(", updateTs=").append(updateTs);
        sb.append(", updateUid=").append(updateUid);
        sb.append(", states=").append(states);
        sb.append("]");
        return sb.toString();
    }

    @Override
    public boolean equals(Object that) {
        if (this == that) {
            return true;
        }
        if (that == null) {
            return false;
        }
        if (getClass() != that.getClass()) {
            return false;
        }
        DocModule other = (DocModule) that;
        return (this.getModuleId() == null ? other.getModuleId() == null : this.getModuleId().equals(other.getModuleId()))
            && (this.getAppId() == null ? other.getAppId() == null : this.getAppId().equals(other.getAppId()))
            && (this.getModuleName() == null ? other.getModuleName() == null : this.getModuleName().equals(other.getModuleName()))
            && (this.getModuleType() == null ? other.getModuleType() == null : this.getModuleType().equals(other.getModuleType()))
            && (this.getPid() == null ? other.getPid() == null : this.getPid().equals(other.getPid()))
            && (this.getModuleCode() == null ? other.getModuleCode() == null : this.getModuleCode().equals(other.getModuleCode()))
            && (this.getmVersion() == null ? other.getmVersion() == null : this.getmVersion().equals(other.getmVersion()))
            && (this.getCreateTs() == null ? other.getCreateTs() == null : this.getCreateTs().equals(other.getCreateTs()))
            && (this.getCreateUid() == null ? other.getCreateUid() == null : this.getCreateUid().equals(other.getCreateUid()))
            && (this.getUpdateTs() == null ? other.getUpdateTs() == null : this.getUpdateTs().equals(other.getUpdateTs()))
            && (this.getUpdateUid() == null ? other.getUpdateUid() == null : this.getUpdateUid().equals(other.getUpdateUid()))
            && (this.getStates() == null ? other.getStates() == null : this.getStates().equals(other.getStates()));
    }

    @Override
    public int hashCode() {
        final int prime = 31;
        int result = 1;
        result = prime * result + ((getModuleId() == null) ? 0 : getModuleId().hashCode());
        result = prime * result + ((getAppId() == null) ? 0 : getAppId().hashCode());
        result = prime * result + ((getModuleName() == null) ? 0 : getModuleName().hashCode());
        result = prime * result + ((getModuleType() == null) ? 0 : getModuleType().hashCode());
        result = prime * result + ((getPid() == null) ? 0 : getPid().hashCode());
        result = prime * result + ((getModuleCode() == null) ? 0 : getModuleCode().hashCode());
        result = prime * result + ((getmVersion() == null) ? 0 : getmVersion().hashCode());
        result = prime * result + ((getCreateTs() == null) ? 0 : getCreateTs().hashCode());
        result = prime * result + ((getCreateUid() == null) ? 0 : getCreateUid().hashCode());
        result = prime * result + ((getUpdateTs() == null) ? 0 : getUpdateTs().hashCode());
        result = prime * result + ((getUpdateUid() == null) ? 0 : getUpdateUid().hashCode());
        result = prime * result + ((getStates() == null) ? 0 : getStates().hashCode());
        return result;
    }
}